package Team.Controller;

import Team.Model.*;
import Team.View.Login.*;
import Team.View.MainFrame.*;

import Team.Listener.Login.*;

public class TeamController
{
    public void initialize()
    {
    	 this.getLoginView().loginButton.addActionListener(new LoginButtonListener(this.loginView, 
    			 this.teamModel, this));
         this.getLoginView().exitButton.addActionListener(new ExitButtonListener(this.loginView, 
        		 this.teamModel));
         this.getLoginView().loadFileButton.addActionListener(new LoadFileButtonListener(this.getLoginView(), 
        		 this.teamModel));
    }
    
    public void setLoginView(TeamLoginView loginView)
    {
    	this.loginView = loginView;
    }
    
    public void setMainFrameView(TeamMainFrameView mainFrameView)
    {
        this.mainFrameView = mainFrameView;
    }
    
    public void setModel(TeamModel teamModel)
    {
    	this.teamModel = teamModel;
    }
    
    public TeamLoginView getLoginView()
    {
    	return this.loginView;
    }
    
    public TeamMainFrameView getMainFramView()
    {
    	return this.mainFrameView;
    }
    
    public TeamModel getModel()
    {
    	return this.teamModel;
    }
    
    private TeamLoginView loginView;
    private TeamMainFrameView mainFrameView;
    private TeamModel teamModel;
}
